<?php
/* @var $this ActivityController */
/* @var $model Activity */
/* @var $form CActiveForm */
?>

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'activity-form',
	'enableAjaxValidation'=>false,
	'enableClientValidation'=>true,	
	'clientOptions'=>array('validateOnSubmit'=>true),
)); ?>

<ul class="form_list form_list2">

	<li class="title">
		<span class="fs_14 fw_b"><?php echo ($model->isNewRecord)?Yii::t('glo','Create'):Yii::t('glo','Update') ?> Activity</span>
	</li>
	
	<?php echo $form->errorSummary($model); ?>

	<li class="c_f">
		<span class="tit"><?php echo $form->labelEx($model,'zac_title'); ?>：</span>
		<div class="cont f_l">
			<?php echo $form->textField($model,'zac_title',array('size'=>50,'maxlength'=>50)); ?>
			<?php echo $form->error($model,'zac_title'); ?>
		</div>
	</li>

	<li class="c_f">
		<span class="tit"><?php echo $form->labelEx($model,'zac_start_time'); ?>：</span>
		<div class="cont f_l">
			<?php echo $form->textField($model,'zac_start_time',array('class'=>'t_ipt w_160','onclick'=>"WdatePicker({dateFmt:'yyyy-MM-dd HH'})")); ?>
			至：
			<?php echo $form->textField($model,'zac_end_time',array('class'=>'t_ipt w_160','onclick'=>"WdatePicker({dateFmt:'yyyy-MM-dd HH'})")); ?>
			<?php echo $form->error($model,'zac_start_time'); ?>
			<?php echo $form->error($model,'zac_end_time'); ?>
		</div>
	</li>

	<li class="c_f">
		<span class="tit"><?php echo $form->labelEx($model,'zac_a_time'); ?>：</span>
		<div class="cont f_l">
			<?php echo $form->textField($model,'zac_a_time',array('class'=>'t_ipt w_160','onclick'=>"WdatePicker({dateFmt:'yyyy-MM-dd HH'})")); ?>
			至：
			<?php echo $form->textField($model,'zac_e_time',array('class'=>'t_ipt w_160','onclick'=>"WdatePicker({dateFmt:'yyyy-MM-dd HH'})")); ?>
			<?php echo $form->error($model,'zac_e_time'); ?>
			<?php echo $form->error($model,'zac_a_time'); ?>
		</div>
	</li>
	
	<li class="c_f">
		<span class="tit"><?php echo $form->labelEx($model,'zac_pic'); ?>：</span>
		<div class="cont f_l">
			<?php echo CHtml::image(empty($model->zac_pic)?'/images/cert_img.jpg':$model->zac_pic,'',array('id'=>'img1','width'=>'200px','height'=>'200px'))?>
			<?php echo CHtml::link('上传活动图片<b class="mem_bgx left"></b><b class="mem_bgx right"></b>'.CHtml::fileField('image','',array('id'=>'uploadimg1','multiple'=>true)),'javascript:',array('class'=>'mem_bgx link_btn filelink mr20','onclick'=>"uploadimg('1')"))?>
			<?php echo $form->hiddenField($model,'zac_pic',array('id'=>'proimage1'))?>
			<?php echo $form->error($model,'zac_pic'); ?>
		</div>
	</li>

	<li class="c_f">
		<span class="tit"><?php echo $form->labelEx($model,'zac_content'); ?>：</span>
		<div class="cont f_l">
			<?php  $this->widget('ext.keditor.KEditor',array('model'=>$model,'name'=>'zac_content')); ?>
			<?php echo $form->error($model,'zac_content'); ?>
		</div>
	</li>

	<li class="c_f"><span class="tit">&nbsp;</span>
		<div class="cont f_l">
		<?php echo CHtml::submitButton($model->isNewRecord ? Yii::t('glo','Create') : Yii::t('glo','Save'),array('class'=>'mem_btn mem_btn20 mr5')); ?>
		</div>
	</li>
</ul>
<?php $this->endWidget(); ?>

<script language="javascript" type="text/javascript" src="<?php echo Yii::app()->baseUrl;?>/js/My97DatePicker/WdatePicker.js"></script>
<script language="javascript" type="text/javascript" src="<?php echo Yii::app()->baseUrl;?>/js/upload_img.js"></script>  